<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>文章详情</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        body {
            background-color: #eff2f5;
        }

        .top {
            height: 60px;
            background-color: white;
            box-shadow: 4px 4px 4px #ccc;

        }
        .top span{
            float: right;
        }
        .body {
            width: 1300px;
            margin: auto;
            display: flex;
            justify-content: center;
            flex-wrap: wrap;
        }

        .titleLan {
            width: 60%;
            
            margin: auto;
            display: flex;
            justify-content: space-between;
            flex-wrap: wrap;
            margin-top: 30px;
        }

        img {
            width: 60%;
            height: 200px;
            display: block;
            margin: auto;
            margin-bottom: 30px;
        }
    </style>

</head>

<body>
    {{each result item}}
    <div class="top">
        <div style="float: left;" onclick="window.history.go(-1)">返回</div>

        <span>审核状态:{{item.status}}</span>
        <span>分类:{{item.cat_id}}</span>

    </div>

    <div class="body">
        

        <div class="titleLan">

            <h1 class="title" style="width: 100%;margin-bottom: 10px;">
                {{item.title}}
            </h1>

            <span> 作者:{{item.author}}</span>
            <span>{{item.time}}</span>
        </div>


        <img src={{item.img}} alt="" >

        <div id="giao">


        </div>

        {{/each}}
    </div>

</body>
<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.0/jquery.js"></script>
<script>

    giao.insertAdjacentHTML("afterbegin", $('<div>').html('{{result[0].content}}').text());

</script>


</html>